#!/bin/bash

NET="192.168.1."
for i in {0..120}
do
    ADR="${NET}${i}"
    echo "scan $ADR"
    if ping -c 1 $ADR &> /dev/null
    then
        echo "$ADR is alive"
    fi

done

